

import Vue from 'vue'
import VueRouter from 'vue-router'
// import VueRouter from 'vue-router'
import Login from '../view/login'
import Res from '../view/res'
import Art from '../view/art'
import List from '../view/list'
import Nofound from '../view/nofound'
// Vue.use(VueRouter)
Vue.use(VueRouter)

const router = new VueRouter({
  routes: [
    {
      path: '/',

     redirect: Login,
    },
    {
      path: '/login',

      component: Login,
    },
    {
      path: '/res/:uname/:age',

      component: Res,
    },
    {
      path: '/art',

      component: Art,
    },
    {
      path: '/list',

      component: List,
    },
    {
      path: '*',

      component: Nofound,
    },
  ]
})
export default router